package com.cl.auth;

import java.util.Set;

import com.cl.auth.stateless.StatelessUser;
import com.cl.entity.AccessToken;
import com.cl.entity.UUser;

public interface AuthService {

    boolean isNewRequest(String nonce, long timestamp);

    AccessToken login(LoginVo command);

    boolean getTokenAvailable(String command);

    void logout(String accessToken);

    Set<String> getPermissions(Long userId);

    String getSecretKey(String accessToken);

    String getUsername(String accessToken);

    StatelessUser getUser(String accessToken);

    AccessToken refresh(RefreshVo command);
    
    void saveCasToken(UUser user, String casToken);
    
}